import request from '@/utils/request'

// 查询出库列列表
export function listDispatch(query) {
  return request({
    url: '/hcmain/dispatch/list',
    method: 'get',
    params: query
  })
}

// 查询出库列详细
export function getDispatch(id) {
  return request({
    url: '/hcmain/dispatch/' + id,
    method: 'get'
  })
}
// 查询出库信息列表
export function getoutlist(id) {
  return request({
    url: '/hcmain/dispatch/getoutlist',
    method: 'get'
  })
}

// 新增出库列
export function addDispatch(data) {
  return request({
    url: '/hcmain/dispatch',
    method: 'post',
    data: data
  })
}

// 修改出库列
export function updateDispatch(data) {
  return request({
    url: '/hcmain/dispatch',
    method: 'put',
    data: data
  })
}

// 删除出库列
export function delDispatch(id) {
  return request({
    url: '/hcmain/dispatch/' + id,
    method: 'delete'
  })
}
